{% extends 'extends/base_all_.html' %}

{% block content %}



<aside class="main-sidebar sidebar-dark-primary elevation-4">
        <ul class="nav nav-pills nav-sidebar flex-column" data-widget="treeview" role="menu" data-accordion="false">
                <!-- 内容审核 -->
                <li class="nav-item">
                    <a href="#" class="nav-link" id="check-link">
                        <i class="nav-icon fas fa-clipboard-check"></i>
                        <p>内容审核</p>
                    </a>
                </li>

                <!-- 用户封禁 -->
                <li class="nav-item">
                    <a href="#" class="nav-link" id="disable">
                        <i class="nav-icon fas fa-user-slash"></i>
                        <p>用户封禁</p>
                    </a>
                </li>

                <!-- 数据查看 -->
                <li class="nav-item">
                    <a href="#" class="nav-link">
                        <i class="nav-icon fas fa-database"></i>
                        <p>数据查看</p>
                    </a>
                </li>
            

                <!-- 退出登录 -->
                <li class="nav-item" >
                    <a href="#" class="nav-link" id="loginout">
                        <i class="nav-icon fas fa-sign-out-alt"></i>
                        <p>退出登录</p>
                    </a>
                </li>
            </ul>
</aside>

    {% block main %}
    {% endblock %}

<script>
    onUrlsReady(urls=>{
        Element_('check-link').href=urls.page.back.check
        Element_('disable').href=urls.page.back.disable

        Event_('loginout','click',e=>{
            Fetch(urls.service.adminlogin,'delete',{},async res => {
                await Flash(res.msg)
                Redirect(urls.page.login)
            })
        })
    })
</script>

{% endblock %}